﻿using System;
using System.Collections.Generic;
using System.Text;

namespace daSyntaxAnalyser.SyntaxTree
{
    using daBase.Objects;

    public class NameExternalOptionElement : ExternalOptionElement
    {
        private ExpressionElement name;

        public ExpressionElement Name { get { return name; } set { name = value; } }

        public NameExternalOptionElement(TokenInfo Token, ExpressionElement Name, List<TokenInfo> Comments)
            : base(Token, Comments)
        {
            name = Name;
        }

        public override string ToString()
        {
            return string.Format("name {0}", name);
        }

        protected override IEnumerator<ISyntaxTreeElement> CreateEnumerator()
        {
            yield return name;
        }
    }
}
